#pragma strict
//////////////////////////////////////////////////////
///利用iTween从一个点 移动到 另一个点
//////////////////////////////////////////////////////

var to:Vector3;

var time:float = 10 ;

function StartMove () {
	iTween.MoveTo(gameObject,iTween.Hash("position",to,"time",time,"easetype",iTween.EaseType.linear,"looptype",iTween.LoopType.pingPong,"oncomplete","OnComplete"));
}

private function OnComplete(){
	//transform.localEulerAngles.y += 180;
	Destroy(gameObject);
}
